using System;
using System.Text;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using NUnit.Framework;
using AjaxControlToolkit.HTMLEditor.ToolbarButton;

namespace AjaxControlToolkit.Models.NUnitFluent.HTMLEditor.ToolbarButton
{
	
    public partial class SelectOptionTests
    {


        
        [Test]
        public void SelectOptionTests_Property_Value_PropertyAssigned ()
        {
            var objectUnderTest = CreateObject();
            System.String expectedValue;
        
            
            try
            {
                expectedValue = null;
                objectUnderTest.Value = expectedValue;
                Assert.IsTrue((string.IsNullOrEmpty(expectedValue) && string.IsNullOrEmpty(objectUnderTest.Value)) || expectedValue == objectUnderTest.Value);;
            }
            catch (ArgumentException)
            {
                //OK
                return;
            }
            
            
            try
            {
                expectedValue = "";
                objectUnderTest.Value = expectedValue;
                Assert.IsTrue((string.IsNullOrEmpty(expectedValue) && string.IsNullOrEmpty(objectUnderTest.Value)) || expectedValue == objectUnderTest.Value);;
            }
            catch (ArgumentException)
            {
                //OK
                return;
            }
            
            
            try
            {
                expectedValue = "1";
                objectUnderTest.Value = expectedValue;
                Assert.IsTrue((string.IsNullOrEmpty(expectedValue) && string.IsNullOrEmpty(objectUnderTest.Value)) || expectedValue == objectUnderTest.Value);;
            }
            catch (ArgumentException)
            {
                //OK
                return;
            }
            
            
            try
            {
                expectedValue = "x";
                objectUnderTest.Value = expectedValue;
                Assert.IsTrue((string.IsNullOrEmpty(expectedValue) && string.IsNullOrEmpty(objectUnderTest.Value)) || expectedValue == objectUnderTest.Value);;
            }
            catch (ArgumentException)
            {
                //OK
                return;
            }
            
            
            try
            {
                expectedValue = ",";
                objectUnderTest.Value = expectedValue;
                Assert.IsTrue((string.IsNullOrEmpty(expectedValue) && string.IsNullOrEmpty(objectUnderTest.Value)) || expectedValue == objectUnderTest.Value);;
            }
            catch (ArgumentException)
            {
                //OK
                return;
            }
            
            
            try
            {
                expectedValue = "123";
                objectUnderTest.Value = expectedValue;
                Assert.IsTrue((string.IsNullOrEmpty(expectedValue) && string.IsNullOrEmpty(objectUnderTest.Value)) || expectedValue == objectUnderTest.Value);;
            }
            catch (ArgumentException)
            {
                //OK
                return;
            }
            
            
            try
            {
                expectedValue = "abc";
                objectUnderTest.Value = expectedValue;
                Assert.IsTrue((string.IsNullOrEmpty(expectedValue) && string.IsNullOrEmpty(objectUnderTest.Value)) || expectedValue == objectUnderTest.Value);;
            }
            catch (ArgumentException)
            {
                //OK
                return;
            }
            
            
            try
            {
                expectedValue = "1,2,3";
                objectUnderTest.Value = expectedValue;
                Assert.IsTrue((string.IsNullOrEmpty(expectedValue) && string.IsNullOrEmpty(objectUnderTest.Value)) || expectedValue == objectUnderTest.Value);;
            }
            catch (ArgumentException)
            {
                //OK
                return;
            }
            
            
            try
            {
                expectedValue = "a,b,c";
                objectUnderTest.Value = expectedValue;
                Assert.IsTrue((string.IsNullOrEmpty(expectedValue) && string.IsNullOrEmpty(objectUnderTest.Value)) || expectedValue == objectUnderTest.Value);;
            }
            catch (ArgumentException)
            {
                //OK
                return;
            }
            
            
            try
            {
                expectedValue = "1;2;3";
                objectUnderTest.Value = expectedValue;
                Assert.IsTrue((string.IsNullOrEmpty(expectedValue) && string.IsNullOrEmpty(objectUnderTest.Value)) || expectedValue == objectUnderTest.Value);;
            }
            catch (ArgumentException)
            {
                //OK
                return;
            }
            
            
            try
            {
                expectedValue = "a;b;c";
                objectUnderTest.Value = expectedValue;
                Assert.IsTrue((string.IsNullOrEmpty(expectedValue) && string.IsNullOrEmpty(objectUnderTest.Value)) || expectedValue == objectUnderTest.Value);;
            }
            catch (ArgumentException)
            {
                //OK
                return;
            }
            
            
            try
            {
                expectedValue = "http://test.com";
                objectUnderTest.Value = expectedValue;
                Assert.IsTrue((string.IsNullOrEmpty(expectedValue) && string.IsNullOrEmpty(objectUnderTest.Value)) || expectedValue == objectUnderTest.Value);;
            }
            catch (ArgumentException)
            {
                //OK
                return;
            }
            
            
            try
            {
                expectedValue = "test@test.com";
                objectUnderTest.Value = expectedValue;
                Assert.IsTrue((string.IsNullOrEmpty(expectedValue) && string.IsNullOrEmpty(objectUnderTest.Value)) || expectedValue == objectUnderTest.Value);;
            }
            catch (ArgumentException)
            {
                //OK
                return;
            }
            
        
        }    
        
        
        [Test]
        public void SelectOptionTests_Property_Text_PropertyAssigned ()
        {
            var objectUnderTest = CreateObject();
            System.String expectedValue;
        
            
            try
            {
                expectedValue = null;
                objectUnderTest.Text = expectedValue;
                Assert.IsTrue((string.IsNullOrEmpty(expectedValue) && string.IsNullOrEmpty(objectUnderTest.Text)) || expectedValue == objectUnderTest.Text);;
            }
            catch (ArgumentException)
            {
                //OK
                return;
            }
            
            
            try
            {
                expectedValue = "";
                objectUnderTest.Text = expectedValue;
                Assert.IsTrue((string.IsNullOrEmpty(expectedValue) && string.IsNullOrEmpty(objectUnderTest.Text)) || expectedValue == objectUnderTest.Text);;
            }
            catch (ArgumentException)
            {
                //OK
                return;
            }
            
            
            try
            {
                expectedValue = "1";
                objectUnderTest.Text = expectedValue;
                Assert.IsTrue((string.IsNullOrEmpty(expectedValue) && string.IsNullOrEmpty(objectUnderTest.Text)) || expectedValue == objectUnderTest.Text);;
            }
            catch (ArgumentException)
            {
                //OK
                return;
            }
            
            
            try
            {
                expectedValue = "x";
                objectUnderTest.Text = expectedValue;
                Assert.IsTrue((string.IsNullOrEmpty(expectedValue) && string.IsNullOrEmpty(objectUnderTest.Text)) || expectedValue == objectUnderTest.Text);;
            }
            catch (ArgumentException)
            {
                //OK
                return;
            }
            
            
            try
            {
                expectedValue = ",";
                objectUnderTest.Text = expectedValue;
                Assert.IsTrue((string.IsNullOrEmpty(expectedValue) && string.IsNullOrEmpty(objectUnderTest.Text)) || expectedValue == objectUnderTest.Text);;
            }
            catch (ArgumentException)
            {
                //OK
                return;
            }
            
            
            try
            {
                expectedValue = "123";
                objectUnderTest.Text = expectedValue;
                Assert.IsTrue((string.IsNullOrEmpty(expectedValue) && string.IsNullOrEmpty(objectUnderTest.Text)) || expectedValue == objectUnderTest.Text);;
            }
            catch (ArgumentException)
            {
                //OK
                return;
            }
            
            
            try
            {
                expectedValue = "abc";
                objectUnderTest.Text = expectedValue;
                Assert.IsTrue((string.IsNullOrEmpty(expectedValue) && string.IsNullOrEmpty(objectUnderTest.Text)) || expectedValue == objectUnderTest.Text);;
            }
            catch (ArgumentException)
            {
                //OK
                return;
            }
            
            
            try
            {
                expectedValue = "1,2,3";
                objectUnderTest.Text = expectedValue;
                Assert.IsTrue((string.IsNullOrEmpty(expectedValue) && string.IsNullOrEmpty(objectUnderTest.Text)) || expectedValue == objectUnderTest.Text);;
            }
            catch (ArgumentException)
            {
                //OK
                return;
            }
            
            
            try
            {
                expectedValue = "a,b,c";
                objectUnderTest.Text = expectedValue;
                Assert.IsTrue((string.IsNullOrEmpty(expectedValue) && string.IsNullOrEmpty(objectUnderTest.Text)) || expectedValue == objectUnderTest.Text);;
            }
            catch (ArgumentException)
            {
                //OK
                return;
            }
            
            
            try
            {
                expectedValue = "1;2;3";
                objectUnderTest.Text = expectedValue;
                Assert.IsTrue((string.IsNullOrEmpty(expectedValue) && string.IsNullOrEmpty(objectUnderTest.Text)) || expectedValue == objectUnderTest.Text);;
            }
            catch (ArgumentException)
            {
                //OK
                return;
            }
            
            
            try
            {
                expectedValue = "a;b;c";
                objectUnderTest.Text = expectedValue;
                Assert.IsTrue((string.IsNullOrEmpty(expectedValue) && string.IsNullOrEmpty(objectUnderTest.Text)) || expectedValue == objectUnderTest.Text);;
            }
            catch (ArgumentException)
            {
                //OK
                return;
            }
            
            
            try
            {
                expectedValue = "http://test.com";
                objectUnderTest.Text = expectedValue;
                Assert.IsTrue((string.IsNullOrEmpty(expectedValue) && string.IsNullOrEmpty(objectUnderTest.Text)) || expectedValue == objectUnderTest.Text);;
            }
            catch (ArgumentException)
            {
                //OK
                return;
            }
            
            
            try
            {
                expectedValue = "test@test.com";
                objectUnderTest.Text = expectedValue;
                Assert.IsTrue((string.IsNullOrEmpty(expectedValue) && string.IsNullOrEmpty(objectUnderTest.Text)) || expectedValue == objectUnderTest.Text);;
            }
            catch (ArgumentException)
            {
                //OK
                return;
            }
            
        
        }    
        
    }
}

